home *** CD-ROM | disk | FTP | other *** search
/ BCI NET 2 / BCI NET 2.iso / archives / programming / amos / amoslist-0195.lzh / AMOSLIST / text0231.txt < prev    next >
Encoding:
Text File  |  1995-02-01  |  2.4 KB  |  62 lines

  1.  
  2.  
  3. On Mon, 23 Jan 1995, Dolfan in VA wrote:
  4.  
  5. > On Mon, 23 Jan 1995, Marco Beretta wrote:
  6. > > None has some ideas in how to update a object in a fast way without 
  7. > > having to update all the object on the screen (which really works well but 
  8. > > slows everything down!) ?
  9. > Well, if you have TURBO PLUS, couldn't you use the (I can't remember the
  10. > command) Wait VBL like command where you specify which line to wait for
  11. > before continuing?  In other words if you have a scroller at the top of the
  12. > screen and the scroller's bottom is on line 75, just wait till line 76
  13. > before going on to the next loop.
  14. > Make sense?
  15.  
  16. This would be a good thing if I I hadn't to update a window which is extends
  17. from the middle to the bottom of the window. 
  18. I have to wait till the Vertical Blank reach the bottom. Unless there is 
  19. a way to set the start position of the vertical blank! 
  20.  
  21.  
  22. >Many of the interfaces I write run into these problems.  I've found the
  23. >only way of speeding up these kind of re-draws is to break each section of
  24. >the screen, or even each button, into individual procedures.  Thus, when
  25. >the user clicks on a button and you want the button to look "depressed",
  26. >you simply increment a flag and call that button's procedure. 
  27. >Alternatively, as I said, you could create procedures for entire sections,
  28. >such as:
  29.  
  30. >TRANSLATE:  X:_____  Y:_____  Z:_____
  31.  
  32. >This would be in one procedure, so whenever a value in the X, Y, or Z text
  33. >boxes is updated, the entire TRANSLATE procedure is called, updating all
  34. >the pertinent values.
  35.  
  36. No, the problem are not Procedure. They are quite fast... they are great 
  37. for modify a single object... but when you have 3-4 object on the screen 
  38. things become dramatically slow.
  39.  
  40.  
  41.  
  42. I'm thinking to delete all the windows and then update them when you have 
  43. decided the position (or the orientation) of the object. This would make 
  44. object definition quite difficult, though.
  45.  
  46. I watched Imagine way to move and rotate objects. I have tried to use a 
  47. simila way of updating screen, but all resulted in mess (the code has 
  48. become too complicated even for me!) 
  49.  
  50. Another way would be drawing and deleting only the object to be modified 
  51. leaving the backgraoud to corrupt and them update everything when you 
  52. have decided or better when you want (pressing RETURN for example) as 
  53. Imagine do. (But in Imagine background is not corrupted).
  54.  
  55. I also thought of using sprite and bobs... what a mess!!!!
  56.  
  57. However thanks for the help
  58.  
  59. M&F
  60.  
  61.